package com.zhny.aiot.top.iot.insect.pest.plugin;

import com.zhny.aiot.plugin.ICenterFacilities;
import com.zhny.aiot.plugin.IDevice;
import com.zhny.aiot.plugin.model.DeviceEntity;
import com.zhny.aiot.plugin.model.FactoryType;
import com.zhny.aiot.plugin.model.StoreEntity;
import com.zhny.aiot.plugin.topny.TopYNWebFactory;
import com.zhny.aiot.top.iot.insect.pest.plugin.model.InsetPestStoreEntry;
import org.pf4j.Extension;
import org.pf4j.Plugin;
import org.pf4j.PluginWrapper;

public class InsectPestPlugin  extends Plugin {
    public InsectPestPlugin(PluginWrapper wrapper) {
        super (wrapper);
    }
    @Extension
    public static class InsectPestFactory extends TopYNWebFactory {
        @Override
        public IDevice createDevice(ICenterFacilities iCenterFacilities, DeviceEntity deviceEntity) {
            return new InsectPestDevice(this,iCenterFacilities,deviceEntity);
        }

        @Override
        public Class<? extends StoreEntity> storeClass() {
            return InsetPestStoreEntry.class;
        }

        @Override
        public String getId() {
            return "top-iot-insect-pest";
        }

        @Override
        public String getName() {
            return "智能虫情测报灯";
        }

        @Override
        public FactoryType getType() {
            return FactoryType.Picture;
        }
    }
}
